<template>
	<view>
		<view class="content-box">
			<view class="acea-row row-middle row-between title">
				<view>添加联系人</view>
				<view class="close" @click.stop="close">
					<image src="../../static/images/add_icon.png" mode=""></image>
				</view>
			</view>
			<view class="acea-row row-middle row-between item border-b">
				<view class="label-m">姓名</view>
				<view class="item-r sanjiao-right">
					<input class="input-r" type="text" placeholder="请输入姓名" placeholder-class="placeholder-class" v-model="name">
				</view>
			</view>
			<view class="acea-row row-middle row-between item border-b">
				<view class="label-m">电话</view>
				<view class="item-r sanjiao-right">
					<input class="input-r" type="number" placeholder="请输入电话" placeholder-class="placeholder-class" v-model="name">
				</view>
			</view>
			<view class="acea-row row-middle row-between item border-b" v-if="moduleType=='normal'">
				<view class="label-m">身份</view>
				<view class="item-r sanjiao-right">
					<view class="no-data-r">请选择身份</view>
				</view>
			</view>
			<view class="acea-row row-middle row-between item border-b" v-if="moduleType=='company'">
				<view class="label-m">部门</view>
				<view class="item-r sanjiao-right">
					<view class="no-data-r">请选择部门</view>
				</view>
			</view>
			<view class="acea-row row-middle row-between item border-b" v-if="moduleType=='company'">
				<view class="label-m">职位</view>
				<view class="item-r sanjiao-right">
					<view class="no-data-r">请选择职位</view>
				</view>
			</view>
			<view class="btns">
				<view class="white-btn">继续添加</view>
				<view class="red-btn">完成</view>
			</view>
		</view>
		<view class="mask" @click.stop="close">
			
		</view>
	</view>
</template>

<script>
	export default {
		name:"addReleaseContact",
		props:{
			// 判断弹窗类型  normal:普通（姓名，电话，身份）
			// company：品牌（姓名，电话、部门、职位）
			moduleType:{
				type:String,
				default:'normal'
			}
		}
		data() {
			return {
				name:'',
				mobile:'',
				// 身份
				identityList:'',
				identityId:'',
				identity:'',
				// 职位
				positionList:'',
				positionId:'',
				position:'',
				// 部门
				departmentList:'',
				departmentId:'',
				department:'',
			};
		},
		methods:{
			close(){
				this.$emit('close')
			}
		}
	}
</script>

<style lang="scss">
	.content-box{
		width: 100%;
		position: fixed;
		bottom: 0;
		left: 0;
		right: 0;
		border-radius: 30rpx 30rpx 0px 0px;
		background: rgba(255, 255, 255, 1);
		z-index: 99;
		padding: 30rpx 30rpx 70rpx;
		.border-b {
			border-bottom: 1px solid rgba(238, 238, 238, 1);
		}
		.item-r {
			width: calc(100% - 160rpx);
		}
		.no-data-r {
			font-size: 28rpx;
			font-weight: 400;
			color: rgba(212, 212, 212, 1);
			text-align: right;
		}
		.item{
			padding: 30rpx 0;
			.label{
				font-size: 28rpx;
				font-weight: 400;
				color: rgba(128, 128, 128, 1);
			}
			.label-m{
				font-size: 28rpx;
				font-weight: 400;
				color: rgba(255, 0, 0, 1.0);
				position: relative;
				padding-right: 16rpx;
				&::after{
					content: '*';
					display: block;
					position: absolute;
					top: 0;
					right: 0;
				}
			}
		}
	}
	.input-r{
		text-align: right;
	}
	.placeholder-class{
		font-size: 28rpx;
		font-weight: 400;
		color: rgba(212, 212, 212, 1);
	}
	.title{
		font-size: 32rpx;
		font-weight: 400;
		.close{
			width: 40rpx;
			height: 40rpx;
			transform: rotate(45deg);
			image{
				width: 100%;
				height: 100%;
			}
		}
	}
	
	.btns{
		.white-btn{
			width: 330rpx;
			height: 96rpx;
			text-align: center;
			line-height: 96rpx;
			font-size: 32rpx;
			font-weight: 400;
			color: rgba(238, 33, 45, 1);
			border-radius: 10rpx;
			border: 1px solid rgba(238, 33, 45, 1);   
			background: rgba(247, 248, 250, 1);
		}
		.red-btn{
			width: 330rpx;
			height: 96rpx;
			text-align: center;
			line-height: 96rpx;
			font-size: 32rpx;
			font-weight: 400;
			color: rgba(255, 255, 255, 1.0);
			border-radius: 10rpx;
			background: rgba(238, 33, 45, 1);
			border: 1px solid rgba(238, 33, 45, 1);
		}
	}
	
.mask{
	width: 100vw;
	height: 100vh;
	position: fixed;
	top: 0rpx;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.6);
	z-index: 98;
	transition: all 0.3s ease-in-out;
	// opacity: 0;
	// visibility: hidden;
}
</style>